package com.erlin.store.controller;


import com.erlin.store.controller.param.StoreDistanceConfigParam;
import com.erlin.store.service.IStoreDeliveryConfigService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author alin
 * @since 2021-05-25
 */
@RestController
@RequestMapping("/store/config")
@Api(tags = "商户配置中心")
public class StoreConfigController {
    @Autowired
    private IStoreDeliveryConfigService storeDeliveryConfigService;

    @PostMapping("/diliveryConfig")
    @ApiOperation("配送配置")
    public Boolean diliveryConfig(@Validated @RequestBody StoreDistanceConfigParam param){
        return storeDeliveryConfigService.diliveryConfig(param);
    }
}
